package com.ming.service;

import com.ming.getway.MqttGetWay;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class MqttMessageSender {
    @Autowired
    private MqttGetWay mqttGetWay;

    public void sendMsg(String topic, String message) {
        mqttGetWay.sendMsgToMqtt(topic, message);
    }

    public void sendMsg(String topic, int qos, String message) {
        mqttGetWay.sendMsgToMqtt(topic, qos, message);
    }
}
